package blackhouse_server;

import java.sql.SQLException;
import java.util.List;

import com.alibaba.fastjson.JSON;

import blackhouse_dao.readteacher_dao;
import blackhouse_dao.student_dao;
import blackhouse_entity.ResultBean;
import blackhouse_entity.teacher;

public class readteacher_server {
	readteacher_dao stu = new readteacher_dao();
	public List<teacher> seekteacher()
			throws SQLException
	{
		
		String sql = "select * from teacher ";
		return stu.show_teacher(sql);
	}
	//教师班级
	public int addteacher_server(String tId,String classId,String subId) throws SQLException{
		String sql="insert into `tclass` (`tId`, `classId`,`subId`) values ('"+tId+"', '"+classId+"','"+subId+"')";
		return stu.addteacher_dao(sql);
	}

}
